/*      Copyright 2002 Arizona Board of regents on behalf of
 *                  The University of Arizona
 *                     All Rights Reserved
 *         (USE & RESTRICTION - Please read COPYRIGHT file)
 *
 *  Version    : DEVSJAVA 2.7
 *  Date       : 08-15-02
 */


package GenDevsTest;

import java.awt.*;
import GenCol.*;
import java.util.*;
import genDevs.modeling.*;
import genDevs.simulation.*;
import simView.*;

public class HierarCoupledModel1 extends ViewableDigraph
{
    public HierarCoupledModel1()
    {
        super("HierarCoupledModel1");
        addInport("in");
        addOutport("out");
        HierarAtomicModel first = new HierarAtomicModel("first");
        HierarAtomicModel second = new HierarAtomicModel("second");
        add(first);
        add(second);
        addCoupling(first, "out", second, "start");
        addCoupling(first, "out", this, "out");
        //
        addCoupling(second, "out", this, "out");
        addCoupling(this, "in", first, "start");
        addCoupling(first, "drawString", this, "drawString");
        addCoupling(second, "drawString", this, "drawString");
    }

    /**
     * Automatically generated by the SimView program.
     * Do not edit this manually, as such changes will get overwritten.
     */
    public void layoutForSimView()
    {
        preferredSize = new Dimension(532, 172);
        if((ViewableComponent)withName("second")!=null)
             ((ViewableComponent)withName("second")).setPreferredLocation(new Point(253, 25));
        if((ViewableComponent)withName("first")!=null)
             ((ViewableComponent)withName("first")).setPreferredLocation(new Point(77, 90));
    }
}
